package com.weibo.util;


import java.util.Calendar;
import java.util.Date;
import java.util.Timer;
import java.util.TimerTask;

import com.weibo.service.JianceMailService;
import com.weibo.service.JianceService;
import com.weibo.service.JianceWeiboTextService;



/**
 * 每天晚上00：00开始采集程序
 * @author Administrator
 *
 */
public class JianceWeiboSaveTimerTask extends TimerTask{
	 //定义组件  
    private Timer timer;  
    
    public  JianceWeiboSaveTimerTask(){  
    	 timer=new Timer();  
         timer.scheduleAtFixedRate(this, 6*60*1000, 2*60*60*1000);  
    }  
    
    public void run() {  
    	JianceWeiboTextService js = new JianceWeiboTextService();
    	js.saveWeibo();
    }  	
    
    
    
    public static void main(String[] args) {  
        new JianceWeiboSaveTimerTask();  
    }  
      
}
